home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / SourceCode / MiscKit1.7.1 / MiscKit / Headers / misckit / MiscDocManager.h < prev    next >
Encoding:
Text File  |  1995-07-21  |  2.6 KB  |  116 lines

  1. // MiscDocManager.h
  2. //
  3. // by Mike Ferris
  4. // Part of MOKit
  5. // Copyright 1993, all rights reserved.
  6.  
  7. // ABOUT MOKit
  8. // 
  9. // MOKit is a collection of useful and general objects.  Permission is 
  10. // granted by the author to use MOKit in your own programs in any way 
  11. // you see fit.  All other rights to the kit are reserved by the author 
  12. // including the right to sell these objects as part of a LIBRARY or as 
  13. // SOURCE CODE.  In plain English, I wish to retain rights to these 
  14. // objects as objects, but allow the use of the objects as pieces in a 
  15. // fully functional program.  NO WARRANTY is expressed or implied.  The author 
  16. // will under no circumstances be held responsible for ANY consequences to 
  17. // you from the use of these objects.  Since you don't have to pay for 
  18. // them, and full source is provided, I think this is perfectly fair.
  19.  
  20. // ABOUT MODocManager
  21. //
  22. // MODocManager manages a bunch of MODocControllers.
  23.  
  24. #import <appkit/appkit.h>
  25.  
  26. // Forward declarations of class names we'll use for static typing.
  27. @class MiscDocument;
  28.  
  29. @interface MiscDocManager:Object
  30. {
  31.     List *docList;
  32.     MiscDocument *currentDoc;
  33.     List *docClassList;
  34.     
  35.     int untitledCount;
  36.     int frameCycle;
  37.     NXPoint windowStartingLocation;
  38.     
  39.     // quit panel outlets
  40.     id    quitPanel;
  41.     id    buttonMatrix;
  42.     
  43.     // menu outlets
  44.     id    docMenu;
  45.     id    openCell;
  46.     id    newCell;
  47.     id    saveCell;
  48.     id    saveAsCell;
  49.     id    saveToCell;
  50.     id    saveAllCell;
  51.     id    revertCell;
  52.     id    closeCell;
  53.     
  54.     Menu *newMenu;
  55.     MenuCell *newSubmenuCell;
  56.     Menu *openMenu;
  57.     MenuCell *openSubmenuCell;
  58. }
  59.  
  60. + initialize;
  61.  
  62. - init;
  63. - initDocumentClass:(Class)docControllerClass;
  64. - free;
  65. - awakeFromNib;
  66.  
  67. - new:sender;
  68. - newFromDocumentClass:sender;
  69. - open:sender;
  70. - openFromDocumentClass:sender;
  71. - openDocument:(const char *)path withClass:(Class)docClass;
  72.  
  73. - save:sender;
  74. - saveAs:sender;
  75. - saveTo:sender;
  76. - saveAll:sender;
  77. - revert:sender;
  78. - close:sender;
  79.  
  80. - print:sender;
  81.  
  82. - getNextWindowLocation:(NXPoint *)pt;
  83. - (int)nextUntitledNum;
  84. - setWindowStartingLocation:(const NXPoint *)pt;
  85.  
  86. - addDocument:(MiscDocument *)aDocument;
  87. - removeDocument:(MiscDocument *)aDocument;
  88. - (MiscDocument *)findDocumentForWindow:aWindow;
  89. - (List *)documentList;
  90. - makeDocumentsPerform:(SEL)aMethod with:anArg;
  91.  
  92. - (BOOL)areDocumentsDirty;
  93.  
  94. - setCurrentDocument:(MiscDocument *)aDocument;
  95. - currentDocument;
  96.  
  97. - addDocumentClass:(Class)docControllerClass;
  98. - removeDocumentClass:(Class)docControllerClass;
  99. - (List *)documentClassList;
  100. - (int)docClassCount;
  101.  
  102. - appWillTerminate:sender;
  103. - quitPanelStopModalAction:sender;
  104.  
  105. - windowDidBecomeKey:sender;
  106. - windowDidResignKey:sender;
  107.  
  108. - (BOOL)menuUpdate:menuCell;
  109.  
  110. - awake;
  111. - read:(NXTypedStream *)strm;
  112. - write:(NXTypedStream *)strm;
  113.  
  114. @end
  115.  
  116.